home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c-part2 / 10026 < prev    next >
Encoding:
Text File  |  1996-08-05  |  716 b   |  33 lines

  1. Path: verkko.uwasa.fi!news
  2. From: mkuljukk@walli.uwasa.fi
  3. Newsgroups: comp.lang.c
  4. Subject: Beginner port question.
  5. Date: Thu, 14 Mar 1996 20:55:12 GMT
  6. Organization: University of Vaasa, Finland
  7. Message-ID: <4ia10s$3de@verkko.uwasa.fi>
  8. NNTP-Posting-Host: walli.uwasa.fi
  9. X-Newsreader: Forte Agent .99b.112
  10.  
  11.  I am trying to make pc- speaker to beep by giving the port 97
  12. value 79. According to my C tutorial, this should do it. It don't
  13. however, so where is the problem?
  14. ______________________________________
  15.  
  16. #include<stdio.h>
  17. #include<conio.h>
  18. void main (void)
  19. {
  20. int save;
  21. int count=0;
  22. save = inp(97);
  23. outp(97,79);
  24. while(count<10000);
  25. outp(97,save);
  26. }
  27. --
  28. Mikko Kuljukka
  29. pitkΣkatu 46 b 27
  30. 65100 Vaasa
  31. puh:961-3123492
  32.  
  33.